﻿using CarAppDto.Base;
using FluentValidation;

namespace CarAppDto.CarType.BrandDtos
{
    public class ReqAddBrandValidator : AbstractValidator<ReqAddBrand>
    {
        public ReqAddBrandValidator()
        {
            RuleFor(x => x.Name).NotEmpty().Length(1, 128);
            RuleFor(x => x.Code).NotEmpty().Length(1, 20);
        }
    }

    public class ReqAddBrand : BaseAddModel
    {
        /// <summary>
        /// 品牌中文名称
        /// </summary>
        public string? Name { get; set; }

        /// <summary>
        /// 品牌英文名称
        /// </summary>
        public string? EnglishName { get; set; }

        /// <summary>
        /// 品牌代码
        /// </summary>
        public string? Code { get; set; }

        /// <summary>
        /// 品牌归宿地
        /// </summary>
        public string? BelongingPlace { get; set; }

        /// <summary>
        /// 品牌所在地（制造国）
        /// </summary>
        public string? ManufacturingCountry { get; set; }

    }
}
